package pcap;

import jpcap.*;

public class Test {
	public static void main(String[] args) throws Exception{
		
		NetworkInterface[] devices = JpcapCaptor.getDeviceList();
		
		JpcapCaptor captor=JpcapCaptor.openDevice(devices[1], 65535, false, 1);
		 
		//for(int i=0;i<100;i++){
		while(true){
		  //Capturamos un paquete y lo muestreamos
		  System.out.println(captor.getPacket());
		  
		  
		  Thread.sleep(50);
		  if(0==1){
			  break;
		  }
		}
		 
		captor.close();
		
		
		
		}
}




